relations and functions all formulas